import type {
  arr,
  arr1,
  arr2,
  arr3,
  arr4,
  arr5,
  arrUser,
  arrs,
  arrz,
  arrzh,
  objs9
} from '@/types'
import { request } from '@/utils/request'

//获取学院点播数据

export const getVideoData = () => request<arr>('getCollegeRankInfo', 'GET')

//智慧直播总览
export const getVideoTotal = () => request<arr1>('getStudentWatchTotal', 'GET')

//当前直播课程
export const getVideoCourse = () =>
  request<arr2>('getCurrentLiveCourseInfo', 'GET')
//最近访问人员
export const getVideoPerson = () =>
  request<arr3>('getRecentVisitorsInfo', 'GET')
//PPt分析日期
type PPtData = {
  data: string
}
export const getPPTData = () => request<PPtData>('getPPTDate', 'GET')

//PPt分析数据
type PPtData1 = {
  name: string
  value: number
}

export const getPPTData1 = () => request<PPtData1[]>('getServerInfo', 'GET')

//视频接口
export const getVideo = () => request<arr4>('getOnlineClassAddress', 'GET')
//教室总汇
export const getVideoTotal1 = () => request<arr5>('getClassEnableInfo', 'GET')

//累计点播
type Ljdb = {
  value: string
}
export const getLjdb = () => request<Ljdb[]>('getAllDemandCount', 'GET')
//今日点播
export const getJrdb = () => request<Ljdb[]>('getTodayDemandCount', 'GET')
//折线图数据
export const getZxtData = () => request<objs9>('getTodayAccessInfoList', 'GET')
//今日直播课
export const getJrzhidata = () =>
  request<arrs>('getRankingOfCourseVisits', 'GET')
//直播人数接口
export const getZhbrs = () => request<arrz>('getBaseInfoList', 'GET')
//用户反馈
export const getUserFeedback = () =>
  request<arrUser>('getUserCommentInfo', 'GET')
//直播总时长
export const getZhzcs = () => request<arrzh>('getOnlineCourseTimeTotal', 'GET')
